#include <stdio.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <stdlib.h>
#include <unistd.h>
#include <string.h>


int main()
{
    const char * filename = "./record.txt";
    int ret = truncate(filename,50);
    if(ret == -1)
    {
        perror("truncate error:\n");
        exit(-1);
    }

    return 0;
}